package org.zcl.单例;

/**
 * @PROJECT_NAME:
 * @DESCRIPTION: 静态内部类
 * @USER: ZhuChengLin
 * @DATE: 2021/11/22 10:21
 */
public class Singleton {
    private Singleton(){}

    private static class SingletonFactory{
        private static Singleton singletonInstance = new Singleton();
    }

    public static Singleton getInstance(){
        return SingletonFactory.singletonInstance;
    }
}
